import React from 'react';
import ReactDOM from 'react-dom';
import {Router, Route, hashHistory, browserHistory, Link} from 'react-router';

import App from '../jsx/common/App.jsx';
import Login from '../jsx/common/Login.jsx';

import Application from '../jsx/Application.jsx';
import Content from '../jsx/content/Content.jsx';
import Articles from '../jsx/content/Articles.jsx';
import ArticlesZuopin from '../jsx/content/ArticlesZuopin.jsx';
import ArticlesNew from '../jsx/content/ArticlesNew.jsx';
import Column from '../jsx/content/Column.jsx';
import ColumnNew from '../jsx/content/ColumnNew.jsx';
import User from '../jsx/User.jsx';
import Data from '../jsx/Data.jsx';
import System from '../jsx/System.jsx';


ReactDOM.render(
    <Router history={hashHistory}>
        <Route path='/login' component={Login}></Route>
        <Route path='/' component={App}>
						<Route path='/application' component={Application}></Route>
						<Route path='/content' component={Content}></Route>
            <Route path='/content/articles/:id/:typeid' component={Articles}></Route>
            <Route path='/zuopin/articles/:id/:typeid' component={ArticlesZuopin}></Route>
            <Route path='/zuopin/articles/new/:id/:typeid' component={ArticlesNew}></Route>
            <Route path='/zuopin/articles/modify/:id/:typeid/:aid' component={ArticlesNew}></Route>
            <Route path='/content/articles/new/:id/:typeid' component={ArticlesNew}></Route>
            <Route path='/content/articles/modify/:id/:typeid/:aid' component={ArticlesNew}></Route>
						<Route path='/column' component={Column}></Route>
            <Route path='/column/new/:id' component={ColumnNew}></Route>
            <Route path='/column/modify/:id/:typeid' component={ColumnNew}></Route>
            <Route path='/column/sub/:id/:reid' component={ColumnNew}></Route>
						<Route path='/user' component={User}></Route>
						<Route path='/data' component={Data}></Route>
						<Route path='/system' component={System}></Route>
        </Route>
    </Router>
, document.getElementById('app'));
